package com.gadgets.cm01.user.controller;

import com.gadgets.cm01.user.dto.UserChangePwdDTO;
import com.gadgets.cm01.user.dto.UserLoginDTO;
import com.gadgets.framework.common.dto.HttpBaseResp;
import com.gadgets.framework.common.exception.GadgetsServiceException;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * @author UncleXiu
 * @version V1.0.0
 * @data 2020-09-16
 * 
 */
public interface IUserLoginContoller {

    /**
     * 用户登录/退出登录
     * @param request                       请求信息
     * @param response                      应答信息
     * @param userLoginDTO                  登录信息
     * @return                              登录结果
     * @throws GadgetsServiceException      异常信息
     */
    HttpBaseResp userLogin(HttpServletRequest request, HttpServletResponse response, UserLoginDTO userLoginDTO) throws GadgetsServiceException;

    /**
     * 激活用户
     * @param request       请求信息
     * @param response      应答信息
     * @param changePwdDTO  密码修改信息
     */
    public HttpBaseResp<Object> activeUser(HttpServletRequest request, HttpServletResponse response, UserChangePwdDTO changePwdDTO);

}
